#include <windows.h>
#include <gl/glut.h>

void display(){
        glClear(GL_COLOR_BUFFER_BIT);
        glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
        glColor3f(0.0, 1.0, 1.0);

        glBegin(GL_POLYGON);
        glVertex2f(-0.5f,0.2f);
        glVertex2f(-0.5f,0.1f);
        glVertex2f(-0.2f,0.1f);
        glVertex2f(-0.2f,0.2f);
        glEnd();

        glBegin(GL_POLYGON);
        glVertex2f(-0.1f,0.0f);
        glVertex2f(-0.3f,0.5f);
        glVertex2f(-0.4f,0.5f);
        glVertex2f(-0.2f,0.0f);
        glEnd();

        glBegin(GL_POLYGON);
        glVertex2f(-0.4f,0.5f);
        glVertex2f(-0.6f,0.0f);
        glVertex2f(-0.5f,0.0f);
        glVertex2f(-0.3f,0.5f);
        glEnd();
//==========================================================
        glBegin(GL_POLYGON);
        glVertex2f(0.0f,0.5f);
        glVertex2f(0.3f,0.0f);
        glVertex2f(0.4f,0.0f);
        glVertex2f(0.1f,0.5f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(0.0f,0.5f);
        glVertex2f(0.0f,0.0f);
        glVertex2f(0.1f,0.0f);
        glVertex2f(0.1f,0.5f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(0.3f,0.5f);
        glVertex2f(0.3f,0.0f);
        glVertex2f(0.4f,0.0f);
        glVertex2f(0.4f,0.5f);
        glEnd();
//================================================
        glBegin(GL_POLYGON);
        glVertex2f(0.0f,0.5f);
        glVertex2f(0.3f,0.0f);
        glVertex2f(0.4f,0.0f);
        glVertex2f(0.1f,0.5f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.2f,-0.1f);
        glVertex2f(-0.2f,-0.6f);
        glVertex2f(-0.1f,-0.6f);
        glVertex2f(-0.1f,-0.1f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.1f,-0.1f);
        glVertex2f(-0.1f,-0.2f);
        glVertex2f(0.2f,-0.2f);
        glVertex2f(0.2f,-0.1f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(0.1f,-0.2f);
        glVertex2f(0.1f,-0.4f);
        glVertex2f(0.2f,-0.4f);
        glVertex2f(0.2f,-0.2f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.1f,-0.3f);
        glVertex2f(0.1f,-0.3f);
        glVertex2f(0.1f,-0.4f);
        glVertex2f(-0.1f,-0.4f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.1f,-0.4f);
        glVertex2f(0.0f,-0.6f);
        glVertex2f(0.2f,-0.6f);
        glVertex2f(0.1f,-0.4f);
        glEnd();
//==========================================
        glBegin(GL_POLYGON);
        glVertex2f(-0.7f,-0.1f);
        glVertex2f(-0.7f,-0.6f);
        glVertex2f(-0.6f,-0.6f);
        glVertex2f(-0.6f,-0.1f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.6f,-0.2f);
        glVertex2f(-0.6f,-0.1f);
        glVertex2f(-0.3f,-0.1f);
        glVertex2f(-0.3f,-0.2f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.4f,-0.2f);
        glVertex2f(-0.4f,-0.5f);
        glVertex2f(-0.3f,-0.5f);
        glVertex2f(-0.3f,-0.2f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(-0.7f,-0.6f);
        glVertex2f(-0.4f,-0.5f);
        glVertex2f(-0.3f,-0.5f);
        glVertex2f(-0.6f,-0.6f);
        glEnd();
//=======================================
        glBegin(GL_POLYGON);
        glVertex2f(0.3f,-0.1f);
        glVertex2f(0.6f,-0.1f);
        glVertex2f(0.6f,-0.2f);
        glVertex2f(0.3f,-0.2f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(0.3f,-0.5f);
        glVertex2f(0.3f,-0.6f);
        glVertex2f(0.6f,-0.6f);
        glVertex2f(0.6f,-0.5f);
        glEnd();
        glBegin(GL_POLYGON);
        glVertex2f(0.4f,-0.2f);
        glVertex2f(0.4f,-0.5f);
        glVertex2f(0.5f,-0.5f);
        glVertex2f(0.5f,-0.2f);
        glEnd();
        glBegin(GL_LINES);
        glColor3f(0.0,1.0,0.0);
        glColor3f(1.0,0.0,0.0);glVertex2f(-0.9f,0.9f);
        glColor3f(0.0,1.0,0.0);glVertex2f(-0.9f,-0.9f);
        glColor3f(0.0,0.0,1.0);glVertex2f(0.9f,0.9f);
        glColor3f(1.0,0.0,1.0);glVertex2f(0.9f,-0.9f);
        glEnd();
        glBegin(GL_LINES);
        glColor3f(1.0,0.5,0.0);
        glColor3f(1.0,0.0,0.0);glVertex2f(-0.9f,0.9f);
        glColor3f(0.0,1.0,0.0);glVertex2f(0.9f,0.9f);
        glColor3f(0.0,0.0,1.0);glVertex2f(-0.9f,-0.9f);
        glColor3f(1.0,0.0,1.0);glVertex2f(0.9f,-0.9f);
        glEnd();
        glFlush();
   }

void keyboard(unsigned char key, int x, int y)
{
    switch (key)
    {
    case 'u':
    case 'U':
        glRotatef(5.0, 1.0, 0.0, 0.0);
        break;
    case 'd':
    case 'D':
        glRotatef(-5.0, 1.0, 0.0, 0.0);
        break;
    case 'l':
    case 'L':
        glRotatef(5.0, 0.0, 1.0, 0.0);
        break;
    case 'r':
    case 'R':
        glRotatef(-5.0, 0.0, 1.0, 0.0);
    }
    display();
}
void init()  {
        glClearColor( 0.0, 0.0, 0.0, 0.0);
        glMatrixMode(GL_PROJECTION);
        glLoadIdentity();
        gluOrtho2D(-1.0, 1.0, -1.0, 1.0);
        glMatrixMode(GL_MODELVIEW);
}
int main( int  argc,  char  **argv)  {
        glutInit( &argc, argv);
        glutInitWindowSize(400,340);
        glutInitWindowPosition(200, 100);
        glutCreateWindow("Lefi_Andri_L_06.2011.1.05751");
glutDisplayFunc(display);
        init();
        glutKeyboardFunc(keyboard);
        glutMainLoop();
      return 0;
}
ok